%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% {{{ Infos
% Beamer Presentation
% LaTeX Template
% Version 1.0 (10/11/12)
%
% This template has been downloaded from:
% http://www.LaTeXTemplates.com
% Special version modified and used by Li CHENG (https://lonaparte.github.io/logos-blog/)
% Version 1.0 (19/05/18)
%
% License:
% CC BY-NC-SA 3.0 (http://creativecommons.org/licenses/by-nc-sa/3.0/)
% }}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%----------------------------------------------------------------------------------------
%	PACKAGES AND THEMES
%----------------------------------------------------------------------------------------

% {{{
\documentclass{beamer}

\mode<presentation> {

\usetheme{Madrid}
\usecolortheme{beaver}
\setbeamercolor{section number projected}{bg=darkred,fg=white}
\setbeamercolor{subsection number projected}{bg=darkred}
\setbeamercolor*{bibliography entry author}{fg=black}
\setbeamercolor*{bibliography entry title}{parent=palette primary}
\setbeamercolor*{bibliography entry location}{fg=black}
% \setbeamertemplate{theorems}[numbered]
\usefonttheme{professionalfonts}
\setbeamertemplate{caption}[numbered]
\setbeamertemplate{footline}[page number]
\setbeamertemplate{background}{\includegraphics[height=\paperheight,width=\paperwidth]{figures/background.png}}
\hypersetup{pdfpagemode=FullScreen}
}
\setbeamertemplate{navigation symbols}{}% 去掉下面没用的导航条

\defbeamertemplate*{footline}{ccnu theme}{%
    \leavevmode%
    \hbox{%
    \begin{beamercolorbox}[wd=.5\paperwidth,ht=2.25ex,dp=1ex,center]{title in head/foot}%
    \usebeamerfont{title in head/foot}\insertshorttitle
    \end{beamercolorbox}%
    \begin{beamercolorbox}[wd=.42\paperwidth,ht=2.25ex,dp=1ex,center]{author in head/foot}%
    \usebeamerfont{author in head/foot}{\insertshortauthor, \insertshortdate}
    \end{beamercolorbox}%
    \begin{beamercolorbox}[wd=0.08\paperwidth,ht=2.25ex,dp=1ex,right]{title in head/foot}%
    \insertframenumber{} / \inserttotalframenumber\hspace*{2ex}
    \end{beamercolorbox}}%
    \vskip0pt%
}

\usepackage{graphicx} % Allows including images
\usepackage{booktabs} % Allows the use of \toprule, \midrule and \bottomrule in tables
\usepackage[UTF8]{ctex} % Use Chinese.
\usepackage{wallpaper}
\usepackage{textpos}
\usepackage{ragged2e} % 两端对齐
\justifying\let\raggedright\justifying
\usepackage{tikz} % pdf 画图功能

% Bibliography Settings {{{
\usepackage[backend=bibtex,sorting=none]{biblatex}
\addbibresource{bib.bib} %BibTeX数据文件及位置
\setbeamerfont{footnote}{size=\tiny}
\setbeamertemplate{bibliography item}[text]
% \begin{frame}
% \frametitle{References}
% \footnotesize{
% \begin{thebibliography}{99} % Beamer does not support BibTeX so references must be inserted manually as below
% \bibitem[1]{p1} Dušan Graovac, Marco Pürschel, Andreas Kiep (2006)
% \newblock MOSFET Power Losses Calculation Using the DataSheet Parameters
% \end{thebibliography}
% \begin{thebibliography}{99}
% \bibitem[2]{p2} TOSHIBA: Data sheet of 2SK3569 (2004)
% \newblock https://pdf1.alldatasheet.com/datasheet-pdf/view/122207/TOSHIBA/2SK3569.html
% \end{thebibliography}
% \begin{thebibliography}{99}
% \bibitem[3]{p3} Fairchild: Data sheet of FCP11N60 (2008)
% \newblock http://www.onsemi.com/PowerSolutions/product.do?id=FCP11N60
% \end{thebibliography}
% }
% \end{frame}
% }}}

\usepackage{listings}
\usepackage{xcolor}
\lstset{numbers=left, 
	basicstyle=\tiny\sffamily,
	numbers=left,
 	numberstyle=\tiny,
	frame=none,
	tabsize=4,
	columns=fixed,
	showstringspaces=false,
	showtabs=false,
	keepspaces,
	commentstyle=\color{red},
	keywordstyle=\color{blue},
    breaklines=true,
    backgroundcolor=\color{lightgray!40!white},
    basicstyle=\ttfamily,
    commentstyle=\ttfamily\color{green!40!black},
    morekeywords={myLCL_num, syms, myDamper_num},
    moredelim=*[s][\ttfamily]{:}{:}
} 

\usepackage{wasysym} % 笑脸符号

\newcommand{\fig}[4]{
    \begin{figure}[ht]
    \centering
    \includegraphics[width=#2\textwidth]{figures/#1}
    \caption{#3}
    \label {fig: #4}
    \end{figure}
}

\newcommand{\eq}[2]{
    \begin{equation}
    #1
    \label {eq: #2}
    \end{equation}
}

\newcommand{\figfig}[6]{
    \begin{figure}[ht]
    \begin{minipage}{0.5\textwidth}
    \centering
    \includegraphics[width=1\textwidth]{figures/#1}
    \caption{#2}
    \label {fig: #3}
    \end{minipage}
    \begin{minipage}{0.5\textwidth}
    \centering
    \includegraphics[width=1\textwidth]{figures/#4}
    \caption{#5}
    \label {fig: #6}
    \end{minipage}
    \end{figure}

\newcommand{。}{．} %将正文中的“。”号转换为“.”。
}


% 每个 section 显示一次目录
\AtBeginSection[]
{
	\begin{frame}{目录}
		% \transfade %淡入淡出效果
		\tableofcontents[sectionstyle=show/shaded,subsectionstyle=hide]
		\addtocounter{framenumber}{-1}  %目录页不计算页码
	\end{frame}
}

% }}}


%----------------------------------------------------------------------------------------
%	TITLE PAGE
%----------------------------------------------------------------------------------------
% {{{
\title{标题}
% \title[Short title in bottom]{标题}
%  \\ using the data sheet parameters} % The short title appears at the bottom of every slide, the full title is only on the title page

\author{ Corona } % Your name
% \author[Author in bottom]{\footnotesize{Author I \\ Author II}}
\institute[shorthand] % Your institution as it will appear on the bottom of every slide, may be shorthand to save space
{
西安交通大学 \\ % Your institution for the title page
\medskip
\textit{ Corona@stu.xjtu.edu.cn } % Your email address
}
\date{\today} % Date, can be changed to a custom date

\begin{document}

{\usebackgroundtemplate{\includegraphics[height=\paperheight,width=\paperwidth]{figures/background.png}}

\begin{frame}
\maketitle
\end{frame}}

% }}}

%----------------------------------------------------------------------------------------
%	PRESENTATION SLIDES
%----------------------------------------------------------------------------------------

%------------------------------------------------

\begin{frame}{Frame I}
    
\end{frame}
% -----------------------------------------------

\end{document} 
